<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core">
    <h:head>
        <title>Facelet Title</title>
    </h:head>
    <h:body>
        <ui:composition template="../Master/MasterPage.xhtml">
            <ui:define name="isa1">
                <p:growl id="messages" showDetail="true" sticky="true"/>
                <h:outputText value="#{malbum_Edit.message}" escape="false"/>
                <div class="t-title" style="border-bottom: 1px solid #d1d0d1">
                    <h3><h:commandLink value="MANAGER ALBUM" action="#{malbum_Edit.redirectIndex}"/>&rarr; EDIT DISC</h3>
                    <div class="t-in">
                        <ui:repeat value="#{malbum_Edit.listAlbumedit}" var="albumedit">
                            <table width="100%">
                                <tr>
                                    <td width="120px" valign="top">
                                        <div style="width: 121px; border: 1px solid #d1d0d1; padding: 2px; border-radius:3px; -moz-border-radius:3px; radius:3px">
                                            <img width="120px" align="top" src="../../#{albumedit.albumImage}"/> 
                                        </div>
                                    </td>
                                    <td valign="top" width="40%" style="padding-left: 5px; padding-right: 5px">
                                        <span style="font-weight: 600" >
                                            #{albumedit.albumName}</span>
                                        <small>Date create/ #{albumedit.albumDateCreate}</small>
                                        <div style="margin-top: 10px">
                                            Name Album:&nbsp;&nbsp;&nbsp;&nbsp;
                                            <input name="intxtnamealbum" class="inputIm"  value="#{albumedit.albumName}"/>
                                        </div>
                                        <div style="margin-top: 10px">
                                            Categories:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<h:outputText class="inputIm"
                                                                                                                           value="#{albumedit.cateName}"/>
                                            <input name="intxtidAlbum" class="inputIm" type="hidden"  value="#{albumedit.albumID}"/>
                                        </div>
                                        <div style="margin-top: 10px">
                                            Album Price:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input value="#{albumedit.albumPrice}" 
                                                                                                   name="intxtpricealbum" class="inputIm"/>
                                            &nbsp;<span style="font-weight: 600">$</span>
                                        </div>
                                        <div style="margin-top: 10px">
                                            Quantity:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                            <input value="#{albumedit.quantity}" name="intxtquantity" class="inputIm"/>
                                        </div>
                                        <div style="margin-top: 10px; text-align: right; padding-right: 30px">
                                            <h:commandButton value="Save" action="#{malbum_Edit.btnsaveInfor_Click}" class="expoler-window" id="btnsaveInfor"/>
                                        </div>
                                    </td>
                                    <td>
                                        <p:editor id="editor_edit" style="width: 100%" value="#{albumedit.albumDetails}" binding="#{malbum_Edit.intxtDetails}"/>  
                                    </td>
                                </tr>
                            </table>
                        </ui:repeat>
                    </div>
                </div>
                <div>
                    <table width="100%">
                        <tr>
                            <td width="48%" valign="top">
                                <div class="t-title">
                                    <h3>List Album</h3>
                                    <div class="t-in">
                                        <p:dataTable id="dataTable_album"
                                                     var="listdtstrore"
                                                     value="#{malbum_Edit.listDataSrote}"  
                                                     paginator="true" rows="10"  
                                                     paginatorTemplate="{CurrentPageReport} 
                                                     {FirstPageLink} {PreviousPageLink} 
                                                     {PageLinks} {NextPageLink} {LastPageLink}
                                                     {RowsPerPageDropdown}"  
                                                     rowsPerPageTemplate="5,10,15"> 
                                            <p:column>  
                                                <input name="listdatastore" type="checkbox" value="#{listdtstrore.dataID}"/>
                                            </p:column>  
                                            <p:column>  
                                                <f:facet name="header">  
                                                    <h:outputText value="Song Name" />  
                                                </f:facet>  
                                                <h:outputText style="color: #000" value="#{listdtstrore.dataName}" />  
                                            </p:column>  
                                            <p:column>  
                                                <f:facet name="header">  
                                                    <h:outputText value="Path" />  
                                                </f:facet>  
                                                <h:outputText value="#{listdtstrore.dataPath}" />  
                                            </p:column>  
                                        </p:dataTable>  
                                    </div>
                                </div>
                            </td>
                            <td width="4%">
                                <h:commandButton id="btnstorealbum" class="expoler-window" value="&rArr;" action="#{malbum_Edit.btnaddtoalbum_Click}"/>
                                <h:commandButton id="btnaddtoalbum" class="expoler-window" value="&lArr;" action="#{malbum_Edit.btnstorealbum_Click}"/>
                            </td>
                            <td width="48%" valign="top">
                                <div class="t-title">
                                    <h3>Song Other</h3>
                                    <div class="t-in">
                                        <p:dataTable id="dataTable" var="listdtstrore" value="#{malbum_Edit.listAllDataStore}"  
                                                     paginator="true" rows="10"  
                                                     paginatorTemplate="{CurrentPageReport}  {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"  
                                                     rowsPerPageTemplate="5,10,15">  
                                            <p:column>  
                                                <input name="albumidstore" type="checkbox" value="#{listdtstrore.dataID}"/>
                                            </p:column> 
                                            <p:column filterBy="#{listdtstrore.dataName}" filterMatchMode="contains">  
                                                <f:facet name="header">  
                                                    <h:outputText value="Song Name" />  
                                                </f:facet>  
                                                <h:outputText style="color: #000" value="#{listdtstrore.dataName}" />  
                                            </p:column>  
                                            <p:column>  
                                                <f:facet name="header">  
                                                    <h:outputText value="Album" />  
                                                </f:facet>  
                                                <h:outputText value="#{listdtstrore.albumName}" />  
                                            </p:column>  
                                        </p:dataTable>  
                                    </div>
                                </div>
                            </td>
                        </tr>
                    </table>
                </div>
                <ui:include src="data_addnew.xhtml">

                </ui:include>
            </ui:define>
        </ui:composition>
    </h:body>
</html>

